/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package de.hshn.mi.ajax;

import javax.faces.bean.ManagedBean;
import javax.faces.bean.RequestScoped;
import org.primefaces.model.tagcloud.DefaultTagCloudItem;
import org.primefaces.model.tagcloud.DefaultTagCloudModel;
import org.primefaces.model.tagcloud.TagCloudModel;

/**
 *This class contains the content of the cloud which is created on the main menu page
 * @author Florian Raab
 */
@ManagedBean
@RequestScoped
public class TagCloudBean {

    private TagCloudModel model;

    public TagCloudBean() {

        model = new DefaultTagCloudModel();
        model.addTag(new DefaultTagCloudItem("Welcome", "#", 1));
        model.addTag(new DefaultTagCloudItem("to ", "#", 3));
        model.addTag(new DefaultTagCloudItem("The", "#", 2));
        model.addTag(new DefaultTagCloudItem("JSF", "#", 5));
        model.addTag(new DefaultTagCloudItem("Project", "#", 4));
        model.addTag(new DefaultTagCloudItem("Page", "#", 2));
        model.addTag(new DefaultTagCloudItem("Java", "#", 5));
        model.addTag(new DefaultTagCloudItem("Bean", "#", 3));
        model.addTag(new DefaultTagCloudItem("Primefaces", "#", 1));

    }

    public TagCloudModel getModel() {
        return model;
    }
}
